//
// Created by pzw on 24-2-22.
//

#ifndef QTTEST_FILE_ADVANCE_H
#define QTTEST_FILE_ADVANCE_H

#include <fcntl.h>
#include <sys/mman.h>

class file_advance {
public:
    int file_advance_fcntl(int fildes, int cmd);
    int file_advance_fcntl(int fildes, int cmd, long arg);
public:
    void *file_advance_mmap(void *addr, size_t len, int prot, int flags, int fildes, off_t off);
    int file_advance_msync(void *addr, size_t len, int flags);
    int file_advance_munmap(void *addr, size_t len);
};

int file_advance_fcntl_main();
int file_advance_mmap_main();
#endif //QTTEST_FILE_ADVANCE_H
